<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Index extends MY_Luckydog
{
	public function __construct()
	{
		parent::__construct();
	}
    public function index()
    {
        $login_status = $this->check_login_status();
        if ($login_status == FALSE){
            header("Location:login");
        }else{
            $this->load->model("/luckydog/User_model","user");
            $total_user = $this->user->get_user_cnt();

            $this->load->model("/luckydog/Review_model","review");
            $total_review = $this->review->get_review_cnt();

            $this->load->model("/luckydog/News_model","news");
            $total_news = $this->news->getnewsCnt();
            $data = [
                'total_user'=>$total_user,
                'total_review'=>$total_review,
                'total_news'=>$total_news,

            ];
        	$this->load->view("/luckydog/index",$data);
        }
    }
}
/* End of file index.php */
/* Location: ./application/controllers/luckydog/index.php */
